package acwing._1_1AlgorithmBasic._2DataStructure;
/**
 * @Project : AlgorithmLearning
 * @Package : ACWing._1_1AlgorithmBasic._2DataStructure
 * @File : Q0841.java
 * @Author : WangRuoyu
 * @Date : 2023/4/1 10:02
 */

import java.io.*;

public class Q0841 {
    static int n;
    static int m;
    static final int N = 100010;
    static long[] h = new long[N];
    static long[] p = new long[N];
    static final int P = 131;

    static void init(String str) {
        p[0] = 1;
        for (int i = 1; i <= n; ++i) {
            h[i] = h[i - 1] * P + str.charAt(i - 1);
            p[i] = p[i - 1] * P;
        }
    }

    static long get(int l, int r) {
        return h[r] - h[l - 1] * p[r - l + 1];
    }

    public static void main(String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        BufferedWriter wr = new BufferedWriter(new OutputStreamWriter(System.out));
        String[] words = br.readLine().split(" ");
        n = Integer.parseInt(words[0]);
        m = Integer.parseInt(words[1]);

        String str = br.readLine();
        init(str);

        for (int i = 0; i < m; ++i) {
            words = br.readLine().split(" ");
            int l1 = Integer.parseInt(words[0]);
            int r1 = Integer.parseInt(words[1]);
            int l2 = Integer.parseInt(words[2]);
            int r2 = Integer.parseInt(words[3]);

            if (get(l1, r1) == get(l2, r2)) {
                wr.write("Yes\n");
            } else {
                wr.write("No\n");
            }
        }
        wr.flush();
    }
}